﻿//ManagerDefault.aspx.cs
////////////////////////////////////////
////////////////////////////////////////
//管理员首页
////////////////////////////////////////
////////////////////////////////////////
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;

public partial class Manager_ManagerDefault : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        //选择最热门，推荐，最新前三项显示。
        /*DataTable tbRecomend = 推荐商品列表
        DataTable tbNewest = 最新商品列表
        DataTable tbHot = 热门商品列表
        //分页绑定，只显示第一页的三项
        PagedDataSource ps1 = new PagedDataSource();
        ps1.DataSource = tbRecomend.DefaultView;    //绑定数据
        ps1.AllowPaging = true; //允许分布
        ps1.PageSize = 3;   //每页显示三项
        ps1.CurrentPageIndex = 0;
        this.dlRecommentGood.DataSource = ps1;
        this.dlRecommentGood.DataBind();    //与图中DataList控件dlRecommendGood绑定
        PagedDataSource ps2 = new PagedDataSource();
        ps2.DataSource = tbRecomend.DefaultView;    //绑定数据
        ps2.AllowPaging = true; //允许分布
        ps2.PageSize = 3;   //每页显示三项
        ps2.CurrentPageIndex = 0;
        this.dlNewestGood.DataSource = ps2;
        this.dlNewestGood.DataBind();   //与图中DataList控件dlNewestGood绑定
        PagedDataSource ps3 = new PagedDataSource();
        ps3.DataSource = tbRecomend.DefaultView;    //绑定数据
        ps3.AllowPaging = true; //允许分布
        ps3.PageSize = 3;   //每页显示三项
        ps3.CurrentPageIndex = 0;
        this.dlHotGood.DataSource = ps3;
        this.dlHotGood.DataBind();  //与图中DataList控件dlHotGood绑定
        */
    }
    protected void LinkButton5_Click(object sender, EventArgs e)
    {
        Response.Redirect("Recommend.aspx");
    }
    protected void LinkButton4_Click(object sender, EventArgs e)
    {
        Response.Redirect("Newest.aspx");
    }
    protected void LinkButton6_Click(object sender, EventArgs e)
    {
        Response.Redirect("Bestseller.aspx");
    }
}
